The rhq-agent.bat and rhq-agent.sh scripts can both take the following command line options.
Option |
Description |
-a, --advanced |
If setup is needed at startup, the advanced setup is run, rather than the basic |
-c, --config=<filename> |
explicitly specifies the configuration file the agent is to use for its configuration; if the preferences node in the file is different than "default", you must specify that preference node name via --pref |
-d, --daemon |
if specified, keyboard input will not be read by the agent. If the --input switch is used to specify a file, it will be processed |
-D<name>[=<value>] |
overrides a configuration preference with the given name with the given value. This also sets the JVM's system property with the same name/value pair (which does not necessarily have to map to a valid agent configuration preference) |
-e, --console=<type> |
Specifies the library implementation to use when console input is to be read. Supported types are: jline, sigar, java. The default is jline. Use java if you find that the agent behaves abnormally while reading console input. |
-g, --purgeplugins |
Deletes all plugins found in the /plugins directory, forcing the agent to re-download all plugins before it can begin managing resources again. |
-h, --help |
displays the help text for the command line arguments of the agent |
-i, --input=<filename> |
specifies an input script containing agent prompt commands that the agent should execute upon startup; if not specified, keyboard input will be read |
-l, --cleanconfig |
Clears out any existing configuration except for any existing security token and purges the agent's persisted data so the agent starts with a clean slate (note that the plugins are not purged, use --purgeplugins for that). The default configuration file will be loaded if --config is not specified. If you only wish to purge the agent's persisted data, without cleaning its configuration settings, use --purgedata. If you wish to clean all configuration, including the agent's security token, see --fullcleanconfig. |
-L, --fullcleanconfig |
Clears out any and all existing configuration and purges the agent's persisted data so the agent starts with a clean slate (note that the plugins are not purged, use --purgeplugins for that). The default configuration file will be loaded if --config is not specified. If you only wish to purge the agent's persisted data, without cleaning its configuration settings, use --purgedata. |
-n, --nostart |
If specified, the agent will not be automatically started |
-o, --output=<filename> |
specifies an output file that all non-log output will be written to. This does not affect the log messages - those go to the file as specified in the log4j.xml configuration |
-p, --pref=<preferences name> |
defines the preferences node name that the agent's configuration is known as. This allows the agent to reuse persisted preferences under this preferences name (and is how you can have multiple configuration sets defined and start the agent with one of them) |
-s, --setup |
Forces the agent to ask basic setup questions, even if the agent has already been fully configured. If --advanced was also specified, the advanced setup questions will be asked. |
-t, --nonative |
Forces the agent to disable the native system, even if the agent was configured for it. |
-u, --purgedata |
Purges the agent's persistent inventory and other data files. This does not erase the agent's configuration settings, use --cleanconfig if you wish to clean the agent's configuration along with purging its persisted data. Note also that the plugins are not purged, use --purgeplugins for that. |